$(function(){
	var uid = localStorage.getItem("send_private_massage_id");
	
	$("#sendContent").click(function(){
		var content = $("#person_massage").val();
		console.log("内容:" + content);
		$.ajax({
			type: "POST",
			url: "http://yx.fxtourong.com/V1/Member/sendPrivateLetter",
			data: {
				token: localStorage.getItem("token"),
				b_uid: uid,
				content: content
			},
			dataType: "json",
			success: function(data) {
				console.log(data);
				var code = data.code;
				console.log(code);
				if(code == "1") {
					window.history.back(-1);
				} else {
					alert(data.message + "");
				}
			},
			error: function(e){
				alert("网络异常");
			}
		});
	});
	
});
